ENT.Type = "anim"
ENT.Base = "base_structure"

ENT.PrintName = "Gun Lab"

ENT.Model		= Model("models/props_c17/furnitureboiler001a.mdl")

ENT.HP			= 500
ENT.MaxStructs	= 2
ENT.Power		= 0
ENT.Scraps 		= true 
ENT.Save 		= false
ENT.Cost		= 600

ENT.LastUsed 	= CurTime()

ENT.HealthRing	= {500, 20, -45}
ENT.SparkPos 	= Vector(4, 0, 0)

local SWEP = FindMetaTable("Weapon")
function SWEP:GetUpgrade()
	return self:GetDTInt(DT_INT_UPGRADE)
end

function SWEP:SetUpgrade(level)
	self:SetDTInt(DT_INT_UPGRADE, level)
	if(self.Upgrade ~=nil) then 
		//this is so clientside stuff like recoil and firerate gets set clientside so animations are correct. 
		//we send it to everyone so the gun is upgraded for everyone.
		umsg.Start("gunlab_upgrade")
		umsg.Entity(self)
		umsg.End()
		return self:Upgrade() 
	end
end